# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Carlo Landmeter <clandmeter@gmail.com>
pkgname=unixodbc
pkgver=2.3.7
pkgrel=2
pkgdesc="ODBC is an open specification to access Data Sources"
url="http://www.unixodbc.org/"
arch="all"
license="LGPL-2.0-or-later"
options="!check"  # No test suite.
makedepends="readline-dev"
subpackages="$pkgname-static $pkgname-dev $pkgname-doc"
source="http://www.unixodbc.org/unixODBC-${pkgver}.tar.gz"

builddir="$srcdir/unixODBC-$pkgver"

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--disable-nls \
		--enable-gui=no \
		--enable-static
	make
}

package() {
	cd "$builddir"
	make -j1 DESTDIR="$pkgdir" install
}

sha512sums="a87afeaaa0476f4ae6345c7021b3af52718944e599abb595c864d9126744a21341889802512a1de3ebaf86ac89e7f8b1bbd7f8f5285e8f4bccf928bd1585ff70  unixODBC-2.3.7.tar.gz"
